#ifndef MUSIC_H
#define MUSIC_H

#include<QUrl>
class Music
{
public:
    Music();
    Music(QUrl url);

    void setMusicId(const QString&musicId);
    void setMusicName(const QString&musicName);
    void setMusicSinger(const QString&musicSinger);
    void setMusicAlbumn(const QString&musicAlbumn);
    void setMusicDuration(qint64 duration);
    void setIsLike(bool isLike);
    void setIsHistory(bool isHistory);
    void setMusicUrl(QUrl musicUrl);
    void setMusicNet();

    QString getMusicName()const;
    QString getMusicSinger()const;
    QString getMusicAlbumn()const;
    qint64 getMusicDuration()const;
    bool getIsLike()const;
    bool getIsHistory()const;
    QUrl getMusicUrl()const;
    QString getMusicId()const;
    bool getIsFromNet()const;

    QString getLrcFilePath();
    void InsertMusicToDB();

private:
    void parseMediaMetaMusic();

private:
    QString musicId;
    QString musicName;
    QString musicSinger;
    QString musicAlbumn;
    qint64 duration;
    bool isLike;
    bool isHistory;
    QUrl musicUrl;
    bool isFromNet=false;

};

#endif // MUSIC_H
